if ppd_file is not None and os.path.exists(ppd_file):
if file(ppd_file, 'r').read(8192).find('HP Fax') == -1:
log.error("Fax configuration error. The CUPS fax queue for '%s' is incorrectly configured. Please make sure that the CUPS fax queue is configured with the 'HP Fax' Model/Driver." % printer_name)
sys.exit(1)
if not args:
log.error("No files specfied to send. Please specify the file(s) to send on the command line.")
usage()
file_list = []
for f in args:
#
# Submit each file to CUPS for rendering by hpijsfax
dev.error_state not in (ERROR_STATE_LOW_SUPPLIES, ERROR_STATE_LOW_PAPER):
log.error("Device is busy or in an error state (code=%d). Please wait for the device to become idle or clear the error and try again." % dev.error_state)